﻿using Microsoft.AspNetCore.Authentication.Cookies;

namespace RuoVea.OmiLogin.Options
{
    /// <summary>
    /// 
    /// </summary>
    public class AppConfig
    {
        /// <summary>
        /// 路由前缀
        /// </summary>
        public string PrefixRoute { get; set; }
        /// <summary>
        /// API分组
        /// </summary>
        public string GroupName { get; set; }
        /// <summary>
        /// scheme
        /// </summary>
        public string Scheme { get; set; } = "RuoVea_" + CookieAuthenticationDefaults.AuthenticationScheme;
        /// <summary>
        /// 若登录 跳转的页面
        /// </summary>
        public string RedirectUrl { get; set; }
        /// <summary>
        /// 登录成功后跳转的页面
        /// </summary>
        public string DefaultUrl { get; set; } = "/home/index";
        /// <summary>
        /// Session过期时间(单位:分钟)
        /// </summary>
        public long IdleTimeout { get; set; } = 120;
        /// <summary>
        /// Cookie -> LoginPath
        /// </summary>
        public string LoginPath { get; set; }
        /// <summary>
        /// 忘记密码路由地址
        /// </summary>

        public string ForgotPasswordUrl { get; set; } = "/auth/forgotpassword";
        /// <summary>
        /// 注册路由地址
        /// </summary>

        public string RegisterUrl { get; set; } = "/auth/register";

        /// <summary>
        /// 显示多语言
        /// </summary>
        public bool ShowI18n = true;
    }
}
